Metal-semiconductor diodes, also referred to as Schottky diodes are widely used in rectifying circuits because of their low forward voltage drop and fast switching action. Schottky diodes produced on AlGaN/GaN heterostructures benefit from the high breakdown voltage of the GaN and the high mobility and high electron density of the 2DEG layer appearing between the GaN and the AlGaN layer as a result of the difference of piezoelectric and spontaneous polarization. There is, however, the problem of high leakage current when the diode is reverse biased, with high power losses as a consequence. Another problem occurs when a Schottky diode of the above-described type is integrated on one substrate together with a High-Electron-Mobility Transistor (HEMT) that uses the same 2DEG layer for conducting charge. For a power diode, for example, a lower turn-on voltage is desirable, in order to minimize the on-state voltage drop. However, a higher threshold voltage may be desirable for the AlGaN/GaN HEMT, which renders the Schottky diode/HEMT integration difficult.